 package cn.exrick.xboot.modules.content.dao;

 import cn.exrick.xboot.base.XbootBaseDao;
 import cn.exrick.xboot.modules.base.entity.Department;
 import cn.exrick.xboot.modules.content.entity.HontDepartment;

 import java.util.List;


 /**
  * 测试数据处理层
  * @author Exrick
  */
 public interface HontDepartmentDao extends XbootBaseDao<HontDepartment, String> {

  /**
   * 通过父id获取 升序
   * @param parentId
   * @return
   */
  List<HontDepartment> findByParentIdOrderBySortOrder(String parentId);

  /**
   * 通过父id获取 升序 数据权限
   * @param parentId
   * @param departmentIds
   * @return
   */
  List<HontDepartment> findByParentIdAndIdInOrderBySortOrder(String parentId, List<String> departmentIds);

  /**
   * 通过父id和状态获取 升序
   * @param parentId
   * @param status
   * @return
   */
  List<HontDepartment> findByParentIdAndStatusOrderBySortOrder(String parentId, Integer status);

  /**
   * 部门名模糊搜索 升序
   * @param title
   * @return
   */
  List<HontDepartment> findByTitleLikeOrderBySortOrder(String title);

  /**
   * 部门名模糊搜索 升序 数据权限
   * @param title
   * @param departmentIds
   * @return
   */
  List<HontDepartment> findByTitleLikeAndIdInOrderBySortOrder(String title, List<String> departmentIds);

  HontDepartment findByTitle(String departmentTitles);

 }